//
//  TCNavigationItemFavouriteBtn.m
//  陶瓷
//
//  Created by 王戈 on 15/8/23.
//  Copyright (c) 2015年 王戈. All rights reserved.
//

#import "TCNavigationItemFavouriteBtn.h"

@implementation TCNavigationItemFavouriteBtn

+ (instancetype)favouriteBtn {
    TCNavigationItemFavouriteBtn *btn = [[TCNavigationItemFavouriteBtn alloc] init];
//    [btn setImage:[UIImage imageNamed:@"takeout_order_comment_bg_rating_unselected"] forState:UIControlStateNormal];
    [btn setTitle:@"关注" forState:UIControlStateNormal];
    btn.titleLabel.font = [UIFont systemFontOfSize:14];
    btn.size = CGSizeMake(80, 30);
//    [btn sizeToFit];
    
    return btn;
}

- (void)setSelected:(BOOL)selected {
//    UIImage *image = [UIImage imageNamed:selected ? @"takeout_order_comment_bg_rating_selected":@"takeout_order_comment_bg_rating_unselected"];
//    [self setImage:image forState:UIControlStateNormal];
    NSString *title = selected ? @"取消关注" : @"关注";
    [self setTitle:title forState:UIControlStateNormal];
}

@end
